package cn.itcast.goods.feign;

import cn.itcast.goods.pojo.Dish;
import cn.itcast.goods.vo.DishOverViewVO;
import cn.itcast.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient("sky-goods")
public interface DishFegin {

    /**
     * 根据id查询Dish
     */
    @PostMapping("/admin/dish/dish")
    Result<Dish> getDishByDishId(@RequestBody Long dishId);

    /**
     * 查询不同状态菜品的数量
     *
     * @return
     */
    @GetMapping("/admin/dish/feign/getOverviewDishes")
    DishOverViewVO getOverviewDishes();
}
